package ouyangye.first;


import java.util.Scanner;

public class Test {
    public static void main(String[] args) {
        Scanner scanner=new Scanner(System.in);

        System.out.println("圆的半径：");
        double circleRadius=scanner.nextDouble();
        Circle circle=new Circle(circleRadius);
        System.out.println("圆的周长："+circle.getPerimeter());
        System.out.println("圆的面积："+circle.getArea());

        System.out.println("长：");
        double w=scanner.nextDouble();
        System.out.println("宽：");
        double h=scanner.nextDouble();
        Rectangle rectangle=new Rectangle(w,h);
        System.out.println("长方形面积为："+rectangle.getArea());

        GeometricObject g=new GeometricObject();
        System.out.println("原来颜色："+g.getColor());
        g.setColor("red");
        System.out.println("新的颜色："+g.getColor());
        System.out.println("原来的填充状态："+g.getFilled());
        g.setFilled(true);
        System.out.println("新的填充状态："+g.getFilled());
        System.out.println("描述："+g.toString());

        scanner.close();
    }
}